3.4.16 \(\int \cos ^3(c+d x) (a+i a \tan (c+d x))^{5/2} \, dx\) [316]

Optimal. Leaf size=35 \[ -\frac {2 i a \cos ^3(c+d x) (a+i a \tan (c+d x))^{3/2}}{3 d} \]

[Out]

-2/3*I*a*cos(d*x+c)^3*(a+I*a*tan(d*x+c))^(3/2)/d

________________________________________________________________________________________

Rubi [A]
time = 0.05, antiderivative size = 35, normalized size of antiderivative = 1.00, number of steps used = 1, number of rules used = 1, integrand size = 26, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.038, Rules used = {3574} \begin {gather*} -\frac {2 i a \cos ^3(c+d x) (a+i a \tan (c+d x))^{3/2}}{3 d} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[Cos[c + d*x]^3*(a + I*a*Tan[c + d*x])^(5/2),x]

[Out]

(((-2*I)/3)*a*Cos[c + d*x]^3*(a + I*a*Tan[c + d*x])^(3/2))/d

Rule 3574

Int[((d_.)*sec[(e_.) + (f_.)*(x_)])^(m_.)*((a_) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(n_), x_Symbol] :> Simp[2*b*(
d*Sec[e + f*x])^m*((a + b*Tan[e + f*x])^(n - 1)/(f*m)), x] /; FreeQ[{a, b, d, e, f, m, n}, x] && EqQ[a^2 + b^2
, 0] && EqQ[Simplify[m/2 + n - 1], 0]

Rubi steps

\begin {align*} \int \cos ^3(c+d x) (a+i a \tan (c+d x))^{5/2} \, dx &=-\frac {2 i a \cos ^3(c+d x) (a+i a \tan (c+d x))^{3/2}}{3 d}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.38, size = 69, normalized size = 1.97 \begin {gather*} \frac {2 a^2 \cos ^2(c+d x) (-i \cos (c+3 d x)+\sin (c+3 d x)) \sqrt {a+i a \tan (c+d x)}}{3 d (\cos (d x)+i \sin (d x))^2} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[Cos[c + d*x]^3*(a + I*a*Tan[c + d*x])^(5/2),x]

[Out]

(2*a^2*Cos[c + d*x]^2*((-I)*Cos[c + 3*d*x] + Sin[c + 3*d*x])*Sqrt[a + I*a*Tan[c + d*x]])/(3*d*(Cos[d*x] + I*Si
n[d*x])^2)

________________________________________________________________________________________

Maple [B] Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 62 vs. \(2 (29 ) = 58\).
time = 0.87, size = 63, normalized size = 1.80

method result size
default \(-\frac {2 \left (i \cos \left (d x +c \right )-\sin \left (d x +c \right )\right ) \left (\cos ^{2}\left (d x +c \right )\right ) \sqrt {\frac {a \left (i \sin \left (d x +c \right )+\cos \left (d x +c \right )\right )}{\cos \left (d x +c \right )}}\, a^{2}}{3 d}\) \(63\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(cos(d*x+c)^3*(a+I*a*tan(d*x+c))^(5/2),x,method=_RETURNVERBOSE)

[Out]

-2/3/d*(I*cos(d*x+c)-sin(d*x+c))*cos(d*x+c)^2*(a*(I*sin(d*x+c)+cos(d*x+c))/cos(d*x+c))^(1/2)*a^2

________________________________________________________________________________________

Maxima [B] Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 328 vs. \(2 (27) = 54\).
time = 0.63, size = 328, normalized size = 9.37 \begin {gather*} \frac {2 \, {\left (i \, a^{\frac {5}{2}} - \frac {4 i \, a^{\frac {5}{2}} \sin \left (d x + c\right )^{2}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{2}} + \frac {6 i \, a^{\frac {5}{2}} \sin \left (d x + c\right )^{4}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{4}} - \frac {4 i \, a^{\frac {5}{2}} \sin \left (d x + c\right )^{6}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{6}} + \frac {i \, a^{\frac {5}{2}} \sin \left (d x + c\right )^{8}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{8}}\right )} {\left (-\frac {2 i \, \sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1} + \frac {\sin \left (d x + c\right )^{2}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{2}} - 1\right )}^{\frac {5}{2}}}{-3 \, d {\left (\frac {\sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1} + 1\right )}^{\frac {5}{2}} {\left (\frac {\sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1} - 1\right )}^{\frac {5}{2}} {\left (\frac {2 i \, \sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1} + \frac {2 \, \sin \left (d x + c\right )^{2}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{2}} + \frac {6 i \, \sin \left (d x + c\right )^{3}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{3}} + \frac {6 i \, \sin \left (d x + c\right )^{5}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{5}} - \frac {2 \, \sin \left (d x + c\right )^{6}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{6}} + \frac {2 i \, \sin \left (d x + c\right )^{7}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{7}} - \frac {\sin \left (d x + c\right )^{8}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{8}} + 1\right )}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(d*x+c)^3*(a+I*a*tan(d*x+c))^(5/2),x, algorithm="maxima")

[Out]

2*(I*a^(5/2) - 4*I*a^(5/2)*sin(d*x + c)^2/(cos(d*x + c) + 1)^2 + 6*I*a^(5/2)*sin(d*x + c)^4/(cos(d*x + c) + 1)
^4 - 4*I*a^(5/2)*sin(d*x + c)^6/(cos(d*x + c) + 1)^6 + I*a^(5/2)*sin(d*x + c)^8/(cos(d*x + c) + 1)^8)*(-2*I*si
n(d*x + c)/(cos(d*x + c) + 1) + sin(d*x + c)^2/(cos(d*x + c) + 1)^2 - 1)^(5/2)/(d*(sin(d*x + c)/(cos(d*x + c)
+ 1) + 1)^(5/2)*(sin(d*x + c)/(cos(d*x + c) + 1) - 1)^(5/2)*(-6*I*sin(d*x + c)/(cos(d*x + c) + 1) - 6*sin(d*x
+ c)^2/(cos(d*x + c) + 1)^2 - 18*I*sin(d*x + c)^3/(cos(d*x + c) + 1)^3 - 18*I*sin(d*x + c)^5/(cos(d*x + c) + 1
)^5 + 6*sin(d*x + c)^6/(cos(d*x + c) + 1)^6 - 6*I*sin(d*x + c)^7/(cos(d*x + c) + 1)^7 + 3*sin(d*x + c)^8/(cos(
d*x + c) + 1)^8 - 3))

________________________________________________________________________________________

Fricas [B] Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 59 vs. \(2 (27) = 54\).
time = 0.36, size = 59, normalized size = 1.69 \begin {gather*} \frac {\sqrt {2} {\left (-i \, a^{2} e^{\left (4 i \, d x + 4 i \, c\right )} - 2 i \, a^{2} e^{\left (2 i \, d x + 2 i \, c\right )} - i \, a^{2}\right )} \sqrt {\frac {a}{e^{\left (2 i \, d x + 2 i \, c\right )} + 1}}}{6 \, d} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(d*x+c)^3*(a+I*a*tan(d*x+c))^(5/2),x, algorithm="fricas")

[Out]

1/6*sqrt(2)*(-I*a^2*e^(4*I*d*x + 4*I*c) - 2*I*a^2*e^(2*I*d*x + 2*I*c) - I*a^2)*sqrt(a/(e^(2*I*d*x + 2*I*c) + 1
))/d

________________________________________________________________________________________

Sympy [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: SystemError} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(d*x+c)**3*(a+I*a*tan(d*x+c))**(5/2),x)

[Out]

Exception raised: SystemError >> excessive stack use: stack is 8569 deep

________________________________________________________________________________________

Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(d*x+c)^3*(a+I*a*tan(d*x+c))^(5/2),x, algorithm="giac")

[Out]

integrate((I*a*tan(d*x + c) + a)^(5/2)*cos(d*x + c)^3, x)

________________________________________________________________________________________

Mupad [B]
time = 0.91, size = 89, normalized size = 2.54 \begin {gather*} -\frac {a^2\,\sqrt {\frac {a\,\left (\cos \left (2\,c+2\,d\,x\right )+1+\sin \left (2\,c+2\,d\,x\right )\,1{}\mathrm {i}\right )}{\cos \left (2\,c+2\,d\,x\right )+1}}\,\left (-\sin \left (c+d\,x\right )-\sin \left (3\,c+3\,d\,x\right )+\cos \left (c+d\,x\right )\,3{}\mathrm {i}+\cos \left (3\,c+3\,d\,x\right )\,1{}\mathrm {i}\right )}{6\,d} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(cos(c + d*x)^3*(a + a*tan(c + d*x)*1i)^(5/2),x)

[Out]

-(a^2*((a*(cos(2*c + 2*d*x) + sin(2*c + 2*d*x)*1i + 1))/(cos(2*c + 2*d*x) + 1))^(1/2)*(cos(c + d*x)*3i - sin(c
 + d*x) + cos(3*c + 3*d*x)*1i - sin(3*c + 3*d*x)))/(6*d)

________________________________________________________________________________________